public class PC{
        CPU cpu;
        HardDisk harddisk;
        public void show(){
                System.out.println("PC的CPU速度为"+cpu.speed+"M");
                System.out.println("PC的硬盘容量为"+harddisk.amount+"Gb");
        }
        public void setCpu(CPU cpu){
                this.cpu = cpu;
        }
        public void setHarddisk(HardDisk harddisk){
                this.harddisk = harddisk;
        }
        public PC(CPU cpu, HardDisk harddisk){
                this.cpu = cpu;
                this.harddisk = harddisk;
        }
        public PC(){
        
}
}
